package com.GoldMiner.util;

import javax.swing.*;

import static com.GoldMiner.util.Img.gold2;

/**
 * 金块类
 */
public class Gold extends Item {
    public Gold() {
        setCount(4);
        setM(40);
        int randomX = (int) (Math.random() * 600); //随机生成x坐标
        int randomY = (int) (Math.random() * 260 + 200); //随机生成y坐标
        this.setX(randomX);
        this.setY(randomY);
        this.setWidth(52);
        this.setHeight(52);
        this.setImg(gold2.getImage());
    }
}